package com.tanhua.dubbo.mongo.api;

import com.tanhua.model.mongo.UserLike;

import java.util.List;

public interface UserLikeApi {

    //互相喜欢
    long likeEachOther(Long userId);
    //我喜欢
    long iLike(Long userId);
    //粉丝
    long likeMe(Long userId);

    //粉丝
    List<Long> fanCount(Integer page, Integer pagesize, Long userId);
    //返回我关注
    List<Long> loveCount(Integer page, Integer pagesize, Long userId);
    //互相关注列表查询
    List<Long> eachLoveCount(Integer page, Integer pagesize, Long userId);
    //粉丝喜欢
    String saveLike(Long userId, Long userLikeId);
    //取消喜欢
    Boolean deleteLike(Long userId, Long likeUserId);

    //互相喜欢
    boolean isMutualLike(Long id, Long likeUserId);

    //根据id查找
    UserLike findById(Long userId, Long likeUserId);

    //保存
    void save(UserLike userLike1, Boolean isLike);

    //更新
    void update(UserLike userLike, Boolean isLike);

    //是否喜欢
    Boolean findExists(Long userId, Long likeUserId);

    //根据用户id查询
    List<UserLike> findByUserId(Long userId);

}
